package com.swe.chums.dao;

import com.swe.chums.dao.model.RatingType;
import com.swe.chums.dao.model.RatingTypePk;
import com.swe.chums.dao.exceptions.RatingTypeDaoException;
import java.util.List;

public interface RatingTypeDao
{
	/**
	 * Method 'insert'
	 * 
	 * @param dto
	 * @return RatingTypePk
	 */
	public RatingTypePk insert(RatingType dto);

	/** 
	 * Updates a single row in the rating_type table.
	 */
	public void update(RatingTypePk pk, RatingType dto) throws RatingTypeDaoException;

	/** 
	 * Deletes a single row in the rating_type table.
	 */
	public void delete(RatingTypePk pk) throws RatingTypeDaoException;

	/** 
	 * Returns all rows from the rating_type table that match the criteria 'id = :id'.
	 */
	public RatingType findByPrimaryKey(int id) throws RatingTypeDaoException;

	/** 
	 * Returns all rows from the rating_type table that match the criteria ''.
	 */
	public List<RatingType> findAll() throws RatingTypeDaoException;

	/** 
	 * Returns all rows from the rating_type table that match the criteria 'id = :id'.
	 */
	public List<RatingType> findWhereIdEquals(int id) throws RatingTypeDaoException;

	/** 
	 * Returns all rows from the rating_type table that match the criteria 'name = :name'.
	 */
	public List<RatingType> findWhereNameEquals(String name) throws RatingTypeDaoException;

	/** 
	 * Returns the rows from the rating_type table that matches the specified primary-key value.
	 */
	public RatingType findByPrimaryKey(RatingTypePk pk) throws RatingTypeDaoException;

}
